{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Apple Stock"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Introduction:\n",
    "\n",
    "We are going to use Apple's stock price.\n",
    "\n",
    "\n",
    "### Step 1. Import the necessary libraries"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd\n",
    "import os"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 2. Import the dataset from this [address](https://raw.githubusercontent.com/guipsamora/pandas_exercises/master/09_Time_Series/Apple_Stock/appl_1980_2014.csv)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "['Solutions.ipynb',\n",
       " '.ipynb_checkpoints',\n",
       " 'Exercises-with-solutions-code.ipynb',\n",
       " 'appl_1980_2014.csv',\n",
       " 'Exercises.ipynb']"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "os.listdir()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 3. Assign it to a variable apple"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Date</th>\n",
       "      <th>Open</th>\n",
       "      <th>High</th>\n",
       "      <th>Low</th>\n",
       "      <th>Close</th>\n",
       "      <th>Volume</th>\n",
       "      <th>Adj Close</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>2014-07-08</td>\n",
       "      <td>96.27</td>\n",
       "      <td>96.80</td>\n",
       "      <td>93.92</td>\n",
       "      <td>95.35</td>\n",
       "      <td>65130000</td>\n",
       "      <td>95.35</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2014-07-07</td>\n",
       "      <td>94.14</td>\n",
       "      <td>95.99</td>\n",
       "      <td>94.10</td>\n",
       "      <td>95.97</td>\n",
       "      <td>56305400</td>\n",
       "      <td>95.97</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>2014-07-03</td>\n",
       "      <td>93.67</td>\n",
       "      <td>94.10</td>\n",
       "      <td>93.20</td>\n",
       "      <td>94.03</td>\n",
       "      <td>22891800</td>\n",
       "      <td>94.03</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>2014-07-02</td>\n",
       "      <td>93.87</td>\n",
       "      <td>94.06</td>\n",
       "      <td>93.09</td>\n",
       "      <td>93.48</td>\n",
       "      <td>28420900</td>\n",
       "      <td>93.48</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>2014-07-01</td>\n",
       "      <td>93.52</td>\n",
       "      <td>94.07</td>\n",
       "      <td>93.13</td>\n",
       "      <td>93.52</td>\n",
       "      <td>38170200</td>\n",
       "      <td>93.52</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "         Date   Open   High    Low  Close    Volume  Adj Close\n",
       "0  2014-07-08  96.27  96.80  93.92  95.35  65130000      95.35\n",
       "1  2014-07-07  94.14  95.99  94.10  95.97  56305400      95.97\n",
       "2  2014-07-03  93.67  94.10  93.20  94.03  22891800      94.03\n",
       "3  2014-07-02  93.87  94.06  93.09  93.48  28420900      93.48\n",
       "4  2014-07-01  93.52  94.07  93.13  93.52  38170200      93.52"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple = pd.read_csv('appl_1980_2014.csv')\n",
    "apple.head()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 4.  Check out the type of the columns"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Date          object\n",
       "Open         float64\n",
       "High         float64\n",
       "Low          float64\n",
       "Close        float64\n",
       "Volume         int64\n",
       "Adj Close    float64\n",
       "dtype: object"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.dtypes"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 5. Transform the Date column as a datetime type"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [],
   "source": [
    "apple.Date = pd.to_datetime(apple.Date)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "Date         datetime64[ns]\n",
       "Open                float64\n",
       "High                float64\n",
       "Low                 float64\n",
       "Close               float64\n",
       "Volume                int64\n",
       "Adj Close           float64\n",
       "dtype: object"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.dtypes"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 6.  Set the date as the index"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {},
   "outputs": [],
   "source": [
    "apple.set_index('Date', inplace=True)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 7.  Is there any duplicate dates?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Open</th>\n",
       "      <th>High</th>\n",
       "      <th>Low</th>\n",
       "      <th>Close</th>\n",
       "      <th>Volume</th>\n",
       "      <th>Adj Close</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>Date</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>2014-07-08</th>\n",
       "      <td>96.27</td>\n",
       "      <td>96.80</td>\n",
       "      <td>93.92</td>\n",
       "      <td>95.35</td>\n",
       "      <td>65130000</td>\n",
       "      <td>95.35</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-07</th>\n",
       "      <td>94.14</td>\n",
       "      <td>95.99</td>\n",
       "      <td>94.10</td>\n",
       "      <td>95.97</td>\n",
       "      <td>56305400</td>\n",
       "      <td>95.97</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-03</th>\n",
       "      <td>93.67</td>\n",
       "      <td>94.10</td>\n",
       "      <td>93.20</td>\n",
       "      <td>94.03</td>\n",
       "      <td>22891800</td>\n",
       "      <td>94.03</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-02</th>\n",
       "      <td>93.87</td>\n",
       "      <td>94.06</td>\n",
       "      <td>93.09</td>\n",
       "      <td>93.48</td>\n",
       "      <td>28420900</td>\n",
       "      <td>93.48</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-01</th>\n",
       "      <td>93.52</td>\n",
       "      <td>94.07</td>\n",
       "      <td>93.13</td>\n",
       "      <td>93.52</td>\n",
       "      <td>38170200</td>\n",
       "      <td>93.52</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "             Open   High    Low  Close    Volume  Adj Close\n",
       "Date                                                       \n",
       "2014-07-08  96.27  96.80  93.92  95.35  65130000      95.35\n",
       "2014-07-07  94.14  95.99  94.10  95.97  56305400      95.97\n",
       "2014-07-03  93.67  94.10  93.20  94.03  22891800      94.03\n",
       "2014-07-02  93.87  94.06  93.09  93.48  28420900      93.48\n",
       "2014-07-01  93.52  94.07  93.13  93.52  38170200      93.52"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Open</th>\n",
       "      <th>High</th>\n",
       "      <th>Low</th>\n",
       "      <th>Close</th>\n",
       "      <th>Volume</th>\n",
       "      <th>Adj Close</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>Date</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "Empty DataFrame\n",
       "Columns: [Open, High, Low, Close, Volume, Adj Close]\n",
       "Index: []"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.loc[apple.duplicated(),:]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "False"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.duplicated().any() # any()全部为False则返回True。判断是不是全为空值"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "True"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.index.is_unique"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 8.  Ops...it seems the index is from the most recent date. Make the first entry the oldest date."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Open</th>\n",
       "      <th>High</th>\n",
       "      <th>Low</th>\n",
       "      <th>Close</th>\n",
       "      <th>Volume</th>\n",
       "      <th>Adj Close</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>Date</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>1980-12-12</th>\n",
       "      <td>28.75</td>\n",
       "      <td>28.87</td>\n",
       "      <td>28.75</td>\n",
       "      <td>28.75</td>\n",
       "      <td>117258400</td>\n",
       "      <td>0.45</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1980-12-15</th>\n",
       "      <td>27.38</td>\n",
       "      <td>27.38</td>\n",
       "      <td>27.25</td>\n",
       "      <td>27.25</td>\n",
       "      <td>43971200</td>\n",
       "      <td>0.42</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1980-12-16</th>\n",
       "      <td>25.37</td>\n",
       "      <td>25.37</td>\n",
       "      <td>25.25</td>\n",
       "      <td>25.25</td>\n",
       "      <td>26432000</td>\n",
       "      <td>0.39</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1980-12-17</th>\n",
       "      <td>25.87</td>\n",
       "      <td>26.00</td>\n",
       "      <td>25.87</td>\n",
       "      <td>25.87</td>\n",
       "      <td>21610400</td>\n",
       "      <td>0.40</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1980-12-18</th>\n",
       "      <td>26.63</td>\n",
       "      <td>26.75</td>\n",
       "      <td>26.63</td>\n",
       "      <td>26.63</td>\n",
       "      <td>18362400</td>\n",
       "      <td>0.41</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-01</th>\n",
       "      <td>93.52</td>\n",
       "      <td>94.07</td>\n",
       "      <td>93.13</td>\n",
       "      <td>93.52</td>\n",
       "      <td>38170200</td>\n",
       "      <td>93.52</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-02</th>\n",
       "      <td>93.87</td>\n",
       "      <td>94.06</td>\n",
       "      <td>93.09</td>\n",
       "      <td>93.48</td>\n",
       "      <td>28420900</td>\n",
       "      <td>93.48</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-03</th>\n",
       "      <td>93.67</td>\n",
       "      <td>94.10</td>\n",
       "      <td>93.20</td>\n",
       "      <td>94.03</td>\n",
       "      <td>22891800</td>\n",
       "      <td>94.03</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-07</th>\n",
       "      <td>94.14</td>\n",
       "      <td>95.99</td>\n",
       "      <td>94.10</td>\n",
       "      <td>95.97</td>\n",
       "      <td>56305400</td>\n",
       "      <td>95.97</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-08</th>\n",
       "      <td>96.27</td>\n",
       "      <td>96.80</td>\n",
       "      <td>93.92</td>\n",
       "      <td>95.35</td>\n",
       "      <td>65130000</td>\n",
       "      <td>95.35</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>8465 rows × 6 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "             Open   High    Low  Close     Volume  Adj Close\n",
       "Date                                                        \n",
       "1980-12-12  28.75  28.87  28.75  28.75  117258400       0.45\n",
       "1980-12-15  27.38  27.38  27.25  27.25   43971200       0.42\n",
       "1980-12-16  25.37  25.37  25.25  25.25   26432000       0.39\n",
       "1980-12-17  25.87  26.00  25.87  25.87   21610400       0.40\n",
       "1980-12-18  26.63  26.75  26.63  26.63   18362400       0.41\n",
       "...           ...    ...    ...    ...        ...        ...\n",
       "2014-07-01  93.52  94.07  93.13  93.52   38170200      93.52\n",
       "2014-07-02  93.87  94.06  93.09  93.48   28420900      93.48\n",
       "2014-07-03  93.67  94.10  93.20  94.03   22891800      94.03\n",
       "2014-07-07  94.14  95.99  94.10  95.97   56305400      95.97\n",
       "2014-07-08  96.27  96.80  93.92  95.35   65130000      95.35\n",
       "\n",
       "[8465 rows x 6 columns]"
      ]
     },
     "execution_count": 19,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.sort_index()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 9. Get the last business day of each month"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 21,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>Open</th>\n",
       "      <th>High</th>\n",
       "      <th>Low</th>\n",
       "      <th>Close</th>\n",
       "      <th>Volume</th>\n",
       "      <th>Adj Close</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>Date</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>1980-12-31</th>\n",
       "      <td>30.481538</td>\n",
       "      <td>30.567692</td>\n",
       "      <td>30.443077</td>\n",
       "      <td>30.443077</td>\n",
       "      <td>2.586252e+07</td>\n",
       "      <td>0.473077</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1981-01-30</th>\n",
       "      <td>31.754762</td>\n",
       "      <td>31.826667</td>\n",
       "      <td>31.654762</td>\n",
       "      <td>31.654762</td>\n",
       "      <td>7.249867e+06</td>\n",
       "      <td>0.493810</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1981-02-27</th>\n",
       "      <td>26.480000</td>\n",
       "      <td>26.572105</td>\n",
       "      <td>26.407895</td>\n",
       "      <td>26.407895</td>\n",
       "      <td>4.231832e+06</td>\n",
       "      <td>0.411053</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1981-03-31</th>\n",
       "      <td>24.937727</td>\n",
       "      <td>25.016818</td>\n",
       "      <td>24.836364</td>\n",
       "      <td>24.836364</td>\n",
       "      <td>7.962691e+06</td>\n",
       "      <td>0.387727</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1981-04-30</th>\n",
       "      <td>27.286667</td>\n",
       "      <td>27.368095</td>\n",
       "      <td>27.227143</td>\n",
       "      <td>27.227143</td>\n",
       "      <td>6.392000e+06</td>\n",
       "      <td>0.423333</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-03-31</th>\n",
       "      <td>533.593333</td>\n",
       "      <td>536.453810</td>\n",
       "      <td>530.070952</td>\n",
       "      <td>533.214286</td>\n",
       "      <td>5.954403e+07</td>\n",
       "      <td>75.750000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-04-30</th>\n",
       "      <td>540.081905</td>\n",
       "      <td>544.349048</td>\n",
       "      <td>536.262381</td>\n",
       "      <td>541.074286</td>\n",
       "      <td>7.660787e+07</td>\n",
       "      <td>76.867143</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-05-30</th>\n",
       "      <td>601.301905</td>\n",
       "      <td>606.372857</td>\n",
       "      <td>598.332857</td>\n",
       "      <td>603.195714</td>\n",
       "      <td>6.828177e+07</td>\n",
       "      <td>86.058571</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-06-30</th>\n",
       "      <td>222.360000</td>\n",
       "      <td>224.084286</td>\n",
       "      <td>220.735714</td>\n",
       "      <td>222.658095</td>\n",
       "      <td>5.745506e+07</td>\n",
       "      <td>91.885714</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2014-07-31</th>\n",
       "      <td>94.294000</td>\n",
       "      <td>95.004000</td>\n",
       "      <td>93.488000</td>\n",
       "      <td>94.470000</td>\n",
       "      <td>4.218366e+07</td>\n",
       "      <td>94.470000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>404 rows × 6 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "                  Open        High         Low       Close        Volume  \\\n",
       "Date                                                                       \n",
       "1980-12-31   30.481538   30.567692   30.443077   30.443077  2.586252e+07   \n",
       "1981-01-30   31.754762   31.826667   31.654762   31.654762  7.249867e+06   \n",
       "1981-02-27   26.480000   26.572105   26.407895   26.407895  4.231832e+06   \n",
       "1981-03-31   24.937727   25.016818   24.836364   24.836364  7.962691e+06   \n",
       "1981-04-30   27.286667   27.368095   27.227143   27.227143  6.392000e+06   \n",
       "...                ...         ...         ...         ...           ...   \n",
       "2014-03-31  533.593333  536.453810  530.070952  533.214286  5.954403e+07   \n",
       "2014-04-30  540.081905  544.349048  536.262381  541.074286  7.660787e+07   \n",
       "2014-05-30  601.301905  606.372857  598.332857  603.195714  6.828177e+07   \n",
       "2014-06-30  222.360000  224.084286  220.735714  222.658095  5.745506e+07   \n",
       "2014-07-31   94.294000   95.004000   93.488000   94.470000  4.218366e+07   \n",
       "\n",
       "            Adj Close  \n",
       "Date                   \n",
       "1980-12-31   0.473077  \n",
       "1981-01-30   0.493810  \n",
       "1981-02-27   0.411053  \n",
       "1981-03-31   0.387727  \n",
       "1981-04-30   0.423333  \n",
       "...               ...  \n",
       "2014-03-31  75.750000  \n",
       "2014-04-30  76.867143  \n",
       "2014-05-30  86.058571  \n",
       "2014-06-30  91.885714  \n",
       "2014-07-31  94.470000  \n",
       "\n",
       "[404 rows x 6 columns]"
      ]
     },
     "execution_count": 21,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "apple.resample('BM').mean()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 10.  What is the difference in days between the first day and the oldest"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 11.  How many months in the data we have?"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Step 12. Plot the 'Adj Close' value. Set the size of the figure to 13.5 x 9 inches"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### BONUS: Create your own question and answer it."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 22,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<AxesSubplot:xlabel='Date'>"
      ]
     },
     "execution_count": 22,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXcAAAD+CAYAAADBCEVaAAAAOXRFWHRTb2Z0d2FyZQBNYXRwbG90bGliIHZlcnNpb24zLjMuMSwgaHR0cHM6Ly9tYXRwbG90bGliLm9yZy/d3fzzAAAACXBIWXMAAAsTAAALEwEAmpwYAAArgklEQVR4nO3deXxcZb3H8c8ve5MmbdOk+5KWtrRlp6WLtIAUhAtowReoiIgsoqiAXu9VXBClAvWqiKB4QUAqqwh4QShrWaSsdmErLRRaaAtd0i1dss7Mc/84J+kkmWSS2TP5vl+vvObs88tk8jvPec5znsecc4iISHbJSXcAIiKSeEruIiJZSMldRCQLKbmLiGQhJXcRkSyk5C4ikoWiJnczu83MtpjZ22HLys3sKTNb7b8OCFv3IzN738zeNbMTkhW4iIh0rCsl99uBE9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6pzzh3qnDsA7xHxk/D69e9MFaDkLj2CWstIr2Rme5xzfcPmx+L1NlmBN+rUHXg9dQJ8xzn3knkjPU3C63p4Ad7A3PPxxk8tBP7ovFGGRNJOyV16pbbJ3V+2A29Ep91AyDlXb2bj8Xrvm2pmx+CNnHWKv/2FeIOo/9LMCvG6KT7DeYNAi6RVop5QFckGzYOi5AN/MLND8XrrnNDB9p8BDjaz5gG6+wHj8QcVEUknJXcRWqplgngDFV+BN/TjIXj3peo72g2vI6gnUhKkSDfohqr0emZWCfwv3qDtDq8EvtHvDuFsvO5bwauuKQ3b9QngIjPL948zwcxKEMkAKrlLb9XHzF7Hq4IJ4N1AvdZfdyPwgD+u5bN4g6kAvAkEzOwNvNGhfo/XgmaZ38VrNd6A0CJppxuqIiJZSNUyIiJZSMldRCQLKbmLiGQhJXcRkSyk5C4ikoWU3EVEspCSu4hIFlJyFxHJQv8PDINWP3qvr6cAAAAASUVORK5CYII=\n",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "apple['Adj Close'].plot()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "anaconda-cloud": {},
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.8.3"
  },
  "toc": {
   "base_numbering": 1,
   "nav_menu": {},
   "number_sections": true,
   "sideBar": true,
   "skip_h1_title": false,
   "title_cell": "Table of Contents",
   "title_sidebar": "Contents",
   "toc_cell": false,
   "toc_position": {},
   "toc_section_display": true,
   "toc_window_display": false
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
